﻿function showWindows(url,hei,wid,top,left) {
    var newWin = window.open(url, '', 'height=' + hei + ',width=' + wid + ',top=' + top + ',left=' + left + ',toolbar=no,menubar=no,scrollbars=yes, resizable=yes,location=no,status=no');

    window.onfocus = function() {
        if (newWin && !newWin.closed) {
            newWin.focus();
        }
    };

    window.document.onfocus = function() {
        if (newWin && !newWin.closed) {
            newWin.focus();
        }
    };

    window.document.onclick = function() {
        if (newWin && !newWin.closed) {
            newWin.focus();
        }
    };

    window.document.ondblclick = function() {
        if (newWin && !newWin.closed) {
            newWin.focus();
        }
    };
}